﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using RN.ERP.Web.BasicService;

namespace RN.ERP.Web.UserControl
{
    public partial class WebCorpQualUC : System.Web.UI.UserControl
    {
        BasicServiceClient client = new BasicServiceClient();
        int roleid = 15;
        int classid = 2501;
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                DDBind();
            }
        }
        /// <summary>
        /// 下拉绑定
        /// </summary>
        protected void DDBind()
        {
            ////生成企业对应的资质列表
            //var quals = client.GetCorpQualTypes(roleid, classid);
            //this.CorpQualType.DataSource = quals;
            //this.CorpQualType.DataValueField = "ID";
            //this.CorpQualType.DataTextField = "Title";
            //this.CorpQualType.DataBind();
            //this.CorpQualType.Items.Insert(0, new ListItem("-请选择-", "-1"));
            ////生成企业对应的资质等级列表
            //var certlevel = client.GetCorpQualLevByRoleid(roleid);
            //this.CorpQualLevel.DataSource = certlevel;
            //this.CorpQualLevel.DataValueField = "key";
            //this.CorpQualLevel.DataTextField = "value";
            //this.CorpQualLevel.DataBind();
            //this.CorpQualLevel.Items.Insert(0, new ListItem("-请选择-", "-1"));
        }
        protected void CorpQualType_SelectedIndexChanged(object sender, EventArgs e)
        {
            //Do...........

        }
    }
}